package com.yigo.prc.infra.repo.dataobject;

import com.baomidou.mybatisplus.annotation.IdType;
import com.tangzc.mpe.autotable.annotation.Column;
import com.tangzc.mpe.autotable.annotation.ColumnId;
import com.tangzc.mpe.autotable.annotation.Table;
import com.tangzc.mpe.autotable.strategy.mysql.data.MysqlTypeConstant;
import com.yigo.framework.base.BasePO;
import lombok.Data;

/**
 * @author chenzl
 */
@Data
@Table(value = "prc_spu", comment = "标准商品SPU(档案)表")
public class PrcSpuPO extends BasePO {
    /**
     * 主键Id<br/>
     * 建表通过执行如下SQL控制ID从10000开始递增<br/>
     * ALTER TABLE table_name AUTO_INCREMENT = 10000;<br/>
     */
    @ColumnId(mode = IdType.AUTO, comment = "id主键", type = MysqlTypeConstant.INT, length = 10)
    private Long id;
    /**
     * 商品名称
     */
    @Column(comment = "商品名称", length = 30, notNull = true)
    private String spuName;
    /**
     * 商品条码，多个使用","分隔
     */
    @Column(comment = "商品条码，多个使用,分隔", length = 30, notNull = false)
    private String spuBarCode;

    /**
     * 分类Id
     */
    @Column(comment = "分类Id", length = 30, notNull = true)
    private Long categoryId;

    /**
     * 分类名称
     */
    @Column(comment = "分类名称", length = 30, notNull = true)
    private String categoryName;

    /**
     * 库存单位编码
     */
    @Column(comment = "库存单位编码", length = 30, notNull = true)
    private String unitCode;

    /**
     * 库存单位名称
     */
    @Column(comment = "库存单位名称", length = 30, notNull = true)
    private String unitName;

    /**
     * 品牌编码
     */
    @Column(comment = "品牌编码", length = 30, notNull = false)
    private String brandCode;

    /**
     * 品牌名称
     */
    @Column(comment = "品牌名称", length = 30, notNull = false)
    private String brandName;

    /**
     * 产地
     */
    @Column(comment = "产地", length = 30, notNull = false)
    private String originPlace;
}
